package com.zero.user;

import java.net.Socket;

/**
 * 用户类
 * 
 * @author Zero
 *
 */
public class User {
	private String name;
	private String nickname;
	private String password;
	private Socket socket;

	/**
	 * 有参构造
	 * 
	 * @param id
	 * @param name
	 * @param password
	 * @param socket
	 */
	public User(String name, String nickname, String password, Socket socket) {
		this.name = name;
		this.nickname = nickname;
		this.password = password;
		this.socket = socket;
	}

	public String getName() {
		return name;
	}

	public String getNickname() {
		return nickname;
	}

	public String getPassword() {
		return password;
	}

	public Socket getSocket() {
		return socket;
	}

	@Override
	public String toString() {
		return "User [name=" + name + ", nickname=" + nickname + ", password=" + password + ", socket=" + socket + "]";
	}
}
